<template>
    <div ref="body">
        <Form :label-width="130" inline>
            <Form-item label="属地区划:">
                <area-linkage :areaCode.sync="queryParam.azaa0001"></area-linkage>
            </Form-item>

            <Form-item label="申请人姓名:">
                <Input v-model="queryParam.azcp0003" placeholder="请输入申请人姓名" style="width:200px"/>
            </Form-item>

            <Form-item label="申请人身份证号码:">
                <Input v-model="queryParam.azcp0001" placeholder="请输入申请人身份证号码" style="width:200px"/>
            </Form-item>

            <Form-item label="业务类型:">
                <c-dict-select v-model="queryParam.ssca0016" dictCode="handletype"/>
            </Form-item>

            <Row class="button_row">
                  <span style="float: right;">
                 <Button type="primary" @click="searchQuery">查询</Button>
                 <Button type="primary" class="button_item_left" @click="searchResetNew">重置</Button>
            </span>
            </Row>
        </Form>

        <div style="margin-top: 20px">
            <vxe-table border
                       resizable
                       row-id="id"
                       :row-key="true"
                       show-overflow="tooltip"
                       highlight-hover-row
                       align="center"
                       header-align="center"
                       ref="xTree"
                       :loading="Loading"
                       :data="tableData">
                <vxe-table-column field="azcp0003" title="申请人姓名" align="center" min-width="140"/>
                <vxe-table-column field="azcp0001" title="申请人证件号码" align="center" min-width="200"/>
                <vxe-table-column field="azaa0002" title="属地区划" align="center" min-width="220"/>
                <vxe-table-column field="ssca0016_name" title="业务类型" align="center" min-width="100"/>
                <vxe-table-column field="taskname" title="办理阶段" align="center" min-width="200"/>
                <vxe-table-column field="create_name" title="受理人" align="center" min-width="140"/>
                <vxe-table-column field="processtime" title="受理时间" align="center" min-width="160"
                                  :formatter="renderDetailTime"/>
                <vxe-table-column field="tasktime" title="任务开始时间" align="center" min-width="160"
                                  :formatter="renderDetailTime"/>
                <vxe-table-column field="" title="操作" min-width="120" fixed="right">
                    <template v-slot="{ row }">
                        <Button type="info" size="small" style="margin-right: 5px" @click="handle(row)">办理
                        </Button>
                    </template>
                </vxe-table-column>
            </vxe-table>
            <Page :total="dataCount" :page-size="pageSize" show-total class="paging"
                  @on-change="handleTableChange" :current="pageNo"></Page>
        </div>
        <ls-application-modal ref="modalForm" @ok="modalFormOk"/>

    </div>
</template>

<script>
    import {CommonMixin} from '@/views/common/js/CommonMixin'
    import lsApplicationModal from '../ls_application/applicationModal'

    export default {
        name: "process-list-500",
        mixins: [CommonMixin],
        components: {lsApplicationModal},
        data() {
            return {
                columns: [],
                url: {
                    list: "/api/ac/subsistence/ss00000Service/getApprovePageList"
                },
                queryParam: {
                    assistancetype: "500"
                },
                assistancetype: "500",
                Loading: false,
            }
        },
        methods: {
            handle: function (row) {
                var width = this.$refs.body.clientWidth;
                this.$refs.modalForm.edit(row);
                this.$refs.modalForm.width = width + 40;
                this.$refs.modalForm.key = this.uuid();
            },
            searchResetNew() {
                this.queryParam = {};
                this.queryParam.assistancetype = this.assistancetype;
                this.loadData(1);
            },
        },
        created() {
            this.loadData();
        },
    }
</script>

<style scoped>
    .paging {
        float: right;
        margin-top: 10px;
    }
</style>
